Skip to main content

Delete Messages

AutomatR.Slack.Activities.DeleteMessage

The "Delete Messages" activity in AutomatR is part of the Slack Messages activities package, leveraging the Slack API to delete a specific message sent by a user. This activity provides the capability to manage and remove messages within a Slack channel.

Properties

NameDescription
Input
Channel NameThe name of the channel from which the message needs to be deleted. String variables containing the desired channel name.
Time StampTimestamp of the message to be deleted. String variables containing the timestamp of the message to be deleted.
Misc
Display NameProvides a customizable name for the activity displayed in the workflow. The display name enhances clarity and organization within the automation project. String variable or argument containing the desired display name.
Optional
DelaySpecifies the amount of time (in seconds) to wait before executing the "Delete Messages" activity. Integer variables containing the delay duration. Example: If the amount of time is 1000 milliseconds or 1 sec, i.e., 1.
Output
ResultReturns true or false based on the success of the message deletion. Boolean variables indicating whether the message deletion was successful or encountered any errors.

How to use:

  1. Drag and drop the "Delete Messages" activity onto the workflow.
  2. Configure the properties by specifying the channel name and timestamp of the message to be deleted.
  3. Optionally, configure the delay.
  4. Execute the workflow to delete the specified message within the Slack channel.

Example: Consider an example where the "Delete Messages" activity is used to delete a message with a timestamp "1639500000" from a channel named "General":

Delete Messages:
Delay: 2
Channel Name: "General"
Time Stamp: "1639500000"
Result: isDeleteSuccessful

In this example, the activity attempts to delete the message from the "General" channel with the specified timestamp. The result of the operation (success or failure) is stored in the Boolean variable "isDeleteSuccessful" for further handling in the workflow.